package com.topica.database.task;

import com.topica.database.DataBaseHelper;
import com.topica.object.QuizLogItem;

import android.content.Context;

public class UpdateQuizLog extends TopicaDBTask {
	private QuizLogItem item;

	public UpdateQuizLog(Context context, QuizLogItem item) {
		super(context);
		showDialog = false;
		this.item = item;
	}

	@Override
	protected Integer doInBackground(Void... arg0) {
		DataBaseHelper myDbHelper = new DataBaseHelper(
				context.getApplicationContext());
		myDbHelper.updateQuizLog(item.getId(), item.getQuizId(),
				item.getUser_id());
		myDbHelper.close();
		return OK;
	}
}
